
#ifndef TERRAINSAMPLEHANDLER_H
#define TERRAINSAMPLEHANDLER_H

#include <BGroup>
#include <BPointRestraint>
#include <BHandler>
#include <BTerrain>
#include <BBody>
#include <BGroup>

using namespace BWE;

class TerrainSampleHandler : public BHandler
{
public:
	TerrainSampleHandler();
	~TerrainSampleHandler();

	BTerrain* createTerrain(const BString& fileName);

protected:
	virtual void attached(BViewer* viewer);
	virtual void detached(BViewer* viewer);

	virtual void paint(BPainter& painter);
	virtual void render(BRender& render);

private:
	BHolder<BGroup>		_group;
	BBody*		_terrainBody;
};

#endif
